/*
 * Copyright 2009, Qys Creations 
 * 
 *  This file is part of Chameleon DB.
 *
 *  Chameleon DB is free software: you can redistribute it and/or modify
 *  it under the terms of the GNU General Public License as published by
 *  the Free Software Foundation, either version 3 of the License, or
 *  (at your option) any later version.
 *
 *  Chameleon DB is distributed in the hope that it will be useful,
 *  but WITHOUT ANY WARRANTY; without even the implied warranty of
 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *  GNU General Public License for more details.
 *
 *  You should have received a copy of the GNU General Public License
 *  along with Chameleon DB.  If not, see <http://www.gnu.org/licenses/>.
 * 
 * */


import java.util.ArrayList;


public class db_parse_result_insert_into implements db_interface_parse_result{
	public String sTable = "";
	public ArrayList<String> oCols = new ArrayList<String>();
	public ArrayList<Integer> oDataTypes = new ArrayList<Integer>();
	public ArrayList<String> oVals = new ArrayList<String>();
	private int iRes = 0;
	
	public int get_result() {
		return iRes;
	}
	
	public void set_result(int iResult) {
		iRes = iResult;
	}
	
	public db_interface_result run_query(db_server oServer, db_session oSession) {
		return  new db_engine().insert_into_table(sTable, oCols, oDataTypes, oVals, oServer.oDatabases.get(oSession.iCurrentDatabase));
	}
}
